//mock需要使用commonjs语法
const Mock = require("mockjs");
const data = require('./json/data.json')
//需要多个动态路径就得用多个mock函数
Mock.mock("/mock/goods",{
    code:200,
    ok:true,
    message:"success",
    data:data.goods
});
Mock.mock("/mock/ratings",{
    code:200,
    ok:true,
    message:"success",
    data:data.ratings
});
Mock.mock("/mock/seller",{
    code:200,
    ok:true,
    message:"success",
    data:data.seller
})